<?php
    require_once './config/config.php';
    require_once './model/db.php';
    require_once './model/products.php';
    $product = new Products();
    $products = $product->product_women();
    $products2 = $product->product_men();
    $products3 = $product->product_coats();
    $products4 = $product->product_hat();
    $products5 = $product->product_shoe();
    if(!empty($_GET["action"])){
        require './controller/addcart.php';
        print'<script type="text/javascript">';
        print'location.href = "index.php";';
        print'</script>';
    }     
?>
<div class="category-tab"><!--category-tab-->
						<div class="col-sm-12">
							<ul class="nav nav-tabs">
								<li class="active"><a href="#tshirt" data-toggle="tab">Giày</a></li>
								<li><a href="#blazers" data-toggle="tab">Nón</a></li>
								<li><a href="#sunglass" data-toggle="tab">Áo khoác</a></li>
								<li><a href="#kids" data-toggle="tab">Nam</a></li>
								<li><a href="#poloshirt" data-toggle="tab">Nữ</a></li>
							</ul>
						</div>
						<div class="tab-content">
							<div class="tab-pane fade active in" id="tshirt" >
                                                            <?php foreach($products5 as $productss) : ?>
								<div class="col-sm-3">
									<div class="product-image-wrapper">
										<div class="single-products">
											<div class="productinfo text-center">
												<img src="<?php echo HOST ?>images/product/<?php echo $productss['image'] ?>" alt="" />
												<h2><?php echo number_format($productss['price'] , 0, ',', '.'); ?> Đồng</h2>
												<p><?php echo $productss['name'] ?></p>
												<a href="index.php?action=add&quantity=1&name=<?php echo $productss['name'] ?>" class="btn btn-default add-to-cart"><i class="fa fa-shopping-cart"></i>Add to cart</a>
											</div>
											
										</div>
									</div>
								</div>
                                                             <?php endforeach; ?>
							</div>
							
							<div class="tab-pane fade" id="blazers" >
                                                            <?php foreach($products4 as $productss) : ?>
								<div class="col-sm-3">
									<div class="product-image-wrapper">
										<div class="single-products">
											<div class="productinfo text-center">
												<img src="<?php echo HOST ?>images/product/<?php echo $productss['image'] ?>" alt="" />
												<h2><?php echo number_format($productss['price'] , 0, ',', '.'); ?> Đồng</h2>
												<p><?php echo $productss['name'] ?></p>
												<a href="index.php?action=add&quantity=1&name=<?php echo $productss['name'] ?>" class="btn btn-default add-to-cart"><i class="fa fa-shopping-cart"></i>Add to cart</a>
											</div>
											
										</div>
									</div>
								</div>
                                                             <?php endforeach; ?>
							</div>
							
							<div class="tab-pane fade" id="sunglass" >
                                                            <?php foreach($products3 as $productss) : ?>
								<div class="col-sm-3">
									<div class="product-image-wrapper">
										<div class="single-products">
											<div class="productinfo text-center">
												<img src="<?php echo HOST ?>images/product/<?php echo $productss['image'] ?>" alt="" />
												<h2><?php echo number_format($productss['price'] , 0, ',', '.'); ?> Đồng</h2>
												<p><?php echo $productss['name'] ?></p>
												<a href="index.php?action=add&quantity=1&name=<?php echo $productss['name'] ?>" class="btn btn-default add-to-cart"><i class="fa fa-shopping-cart"></i>Add to cart</a>
											</div>
											
										</div>
									</div>
								</div>
                                                             <?php endforeach; ?>
							</div>
							
							<div class="tab-pane fade" id="kids" >
                                                            <?php foreach($products2 as $productss) : ?>
								<div class="col-sm-3">
									<div class="product-image-wrapper">
										<div class="single-products">
											<div class="productinfo text-center">
												<img src="<?php echo HOST ?>images/product/<?php echo $productss['image'] ?>" alt="" />
												<h2><?php echo number_format($productss['price'] , 0, ',', '.'); ?> Đồng</h2>
												<p><?php echo $productss['name'] ?></p>
												<a href="index.php?action=add&quantity=1&name=<?php echo $productss['name'] ?>" class="btn btn-default add-to-cart"><i class="fa fa-shopping-cart"></i>Add to cart</a>
											</div>
											
										</div>
									</div>
								</div>
                                                             <?php endforeach; ?>
								
							</div>
							
							<div class="tab-pane fade" id="poloshirt" >
                                                            <?php foreach($products as $productss) : ?>
								<div class="col-sm-3">
									<div class="product-image-wrapper">
										<div class="single-products">
											<div class="productinfo text-center">
												<img src="<?php echo HOST ?>images/product/<?php echo $productss['image'] ?>" alt="" />
												<h2><?php echo number_format($productss['price'] , 0, ',', '.') ?> Đồng</h2>
												<p><?php echo $productss['name'] ?></p>
												<a href="index.php?action=add&quantity=1&name=<?php echo $productss['name'] ?>" class="btn btn-default add-to-cart"><i class="fa fa-shopping-cart"></i>Add to cart</a>
											</div>
											
										</div>
									</div>
								</div>
                                                             <?php endforeach; ?>
								
							</div>
						</div>
					</div><!--/category-tab-->